#ifndef els_string_h
#define els_string_h


#include "els_object.h"
#include "els_vmhost.h"
#include<string.h>
#define FIXMARK		2
#define RESERVEDMARK	3
#define sizestring(l)	((long)sizeof(TString) + \
                         ((long)(l+1)-TSPACK)*(long)sizeof(char))


void els_string_init (els_VmObj *L);
void els_string_resize (els_VmObj *L, stringunit *tb, int newsize);
void els_string_freeall (els_VmObj *L);

TString *els_string_newudata (els_VmObj *L, size_t s, void *udata);
TString *els_string_createudata (els_VmObj *L, void *udata, int tag);
TString *els_string_newlstr (els_VmObj *L, const char *str, size_t l);
TString *els_string_newfixed (els_VmObj *L, const char *str);
TString *els_string_new(els_VmObj *L, const char *str);
#endif
